#define _CRT_SECURE_NO_WARNINGS 1


#include<stdio.h>
#include<string.h>

void my_BubbleQsort(int* a, int len)
{
	int i = 0;
	int flag = 0;
	for (i = 0; i < len - 1; i++)
	{
		int j = 0;
		for (j = 0; j < len - 1 - i; j++)
		{
			if (a[j] > a[j + 1])
			{
				int tmp = a[j];
				a[j] = a[j + 1];
				a[j + 1] = tmp;
				flag = 1;
			}
		}
		if (flag == 0)
		{
			break;
		}

	}

}

int main()
{

	int a[] = { 2,3,1,4,9,0,10,11,33,22,55,44 };
	int len = sizeof(a) / sizeof(a[0]);
	for (int i = 0; i < len; i++)
	{
		printf("%d ", a[i]);
	}
	printf("\n");
	my_BubbleQsort(a, len);
	for (int i = 0; i < len; i++)
	{
		printf("%d ", a[i]);
	}
	return 0;


	return 0;
}